package com.shensi.adminCollect.service.integral.impl;

import com.shensi.adminCollect.domain.integral.IntegralOrder;
import com.shensi.adminCollect.mapper.integral.IntegralOrderMapper;
import com.shensi.adminCollect.service.integral.IIntegralOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 积分消费订单Service业务层处理
 * 
 * @author qujia
 * @date 2021-02-24
 */
@Service
public class IntegralOrderServiceImpl implements IIntegralOrderService 
{
    @Autowired
    private IntegralOrderMapper integralOrderMapper;

    /**
     * 查询积分消费订单
     * 
     * @param id 积分消费订单ID
     * @return 积分消费订单
     */
    @Override
    public IntegralOrder selectIntegralOrderById(Long id)
    {
        return integralOrderMapper.selectIntegralOrderById(id);
    }

    /**
     * 查询积分消费订单列表
     * 
     * @param integralOrder 积分消费订单
     * @return 积分消费订单
     */
    @Override
    public List<IntegralOrder> selectIntegralOrderList(IntegralOrder integralOrder)
    {
        return integralOrderMapper.selectIntegralOrderList(integralOrder);
    }

    /**
     * 新增积分消费订单
     * 
     * @param integralOrder 积分消费订单
     * @return 结果
     */
    @Override
    public int insertIntegralOrder(IntegralOrder integralOrder)
    {
        return integralOrderMapper.insertIntegralOrder(integralOrder);
    }

    /**
     * 修改积分消费订单
     * 
     * @param integralOrder 积分消费订单
     * @return 结果
     */
    @Override
    public int updateIntegralOrder(IntegralOrder integralOrder)
    {
        return integralOrderMapper.updateIntegralOrder(integralOrder);
    }

    /**
     * 批量删除积分消费订单
     * 
     * @param ids 需要删除的积分消费订单ID
     * @return 结果
     */
    @Override
    public int deleteIntegralOrderByIds(Long[] ids)
    {
        return integralOrderMapper.deleteIntegralOrderByIds(ids);
    }

    /**
     * 删除积分消费订单信息
     * 
     * @param id 积分消费订单ID
     * @return 结果
     */
    @Override
    public int deleteIntegralOrderById(Long id)
    {
        return integralOrderMapper.deleteIntegralOrderById(id);
    }
}
